<?php

class Zend_View_Helper_DomesticTotal{
	
	public function domesticTotal($weight,$first_weight=12,$addition_weight=2,$express_rate=true){

		//return $weight;
		
		if($weight==0){
			
			return 0;
			
		}

		$first_weight=12/EXCHANGE_RATE;
		
		$addition_weight=2/EXCHANGE_RATE;
		
		if($express_rate){
		
			$domExtra=(ceil($weight-1)*$addition_weight+$first_weight)*EXPRESS_RATE;
			
		}else{
			
			$domExtra=(ceil($weight-1)*$addition_weight+$first_weight);
			
		}
		
		return number_format($domExtra,2);
		
	}

}
